<script type="text/javascript">
    function setData(isi,elm, isilbl, elmLbl, myDialog){
        $(myDialog).dialog("close");
        document.getElementById(elm).value = isi;
        document.getElementById(elmLbl).value = isilbl;
    }
</script>

<?php Yii::import('application.extensions.CJuiDateTimePicker.CJuiDateTimePicker') ?> 
<?php
/* @var $this SysappaccessruleController */
/* @var $model Sysappaccessrule */
/* @var $form CActiveForm */
?>

<div class="form">

<?php $form=$this->beginWidget('CActiveForm', array(
	'id'=>'sysappaccessrule-form',
	// Please note: When you enable ajax validation, make sure the corresponding
	// controller action is handling ajax validation correctly.
	// There is a call to performAjaxValidation() commented in generated controller code.
	// See class documentation of CActiveForm for details on this.
	'enableAjaxValidation'=>false,
)); ?>

	<p class="note">Fields with <span class="required">*</span> are required.</p>

	<?php echo $form->errorSummary($model); ?>

<table>
    
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'MenuGroupID'); ?></td>
		<td>: <?php echo CHtml::activeNumberField($model,'MenuGroupID',array('id' => 'txt_MenuGroupID', 'size'=>11)); ?> 
                    <?php echo CHtml::button('...', array('onclick'=>'$("#myDialog_MenuGroupID").dialog("open"); return false;',)); ?> 
                    <input type="text" id="lb_MenuGroupID" style="border: 0" readonly="">
                                        
                    <?php $this->beginWidget('zii.widgets.jui.CJuiDialog', array(
                            'id' => 'myDialog_MenuGroupID',
                            'options' => array('title' => 'Sysappaccessrule-MenuGroupID','width' => 600,'height' => 500,'autoOpen' => false,),
                            ));
                            $dialMenuGroupID = new myDialog();
                            $sourceMenuGroupID = $dialMenuGroupID->renderDialog("sysappmenugroup", "MenuGroupID", "txt_MenuGroupID", "lb_MenuGroupID", "MenuGroupName", "#myDialog_MenuGroupID");
                            eval($sourceMenuGroupID);
                        ?>
                    <?php $this->endWidget('zii.widgets.jui.CJuiDialog'); ?> 
                </td>
		<td><?php echo $form->error($model,'MenuGroupID'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'RuleGroupArray'); ?></td>
		<td>: <?php echo CHtml::activeNumberField($model,'RuleGroupArray',array('id' => 'txt_RuleGroupArray', 'size'=>11)); ?></td>
		<td><?php echo $form->error($model,'RuleGroupArray'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'PermissionAccessID'); ?></td>
		<td>: <?php echo CHtml::activeNumberField($model,'PermissionAccessID',array('id' => 'txt_PermissionAccessID', 'size'=>4)); ?> 
                    <?php echo CHtml::button('...', array('onclick'=>'$("#myDialog_PermissionAccessID").dialog("open"); return false;',)); ?> 
                    <input type="text" id="lb_PermissionAccessID" style="border: 0" readonly="">
                                        
                    <?php $this->beginWidget('zii.widgets.jui.CJuiDialog', array(
                            'id' => 'myDialog_PermissionAccessID',
                            'options' => array('title' => 'Sysappaccessrule-PermissionAccessID','width' => 600,'height' => 500,'autoOpen' => false,),
                            ));
                            $dialPermissionAccessID = new myDialog();
                            $sourcePermissionAccessID = $dialPermissionAccessID->renderDialog("masterpermissionaccess", "PermissionAccessID", "txt_PermissionAccessID", "lb_PermissionAccessID", "PermissionAccessName", "#myDialog_PermissionAccessID");
                            eval($sourcePermissionAccessID);
                        ?>
                    <?php $this->endWidget('zii.widgets.jui.CJuiDialog'); ?> 
                </td>
		<td><?php echo $form->error($model,'PermissionAccessID'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'ControllerName'); ?></td>
		<td>: <?php echo CHtml::activeTextField($model,'ControllerName',array('id' => 'txt_ControllerName','size'=>60,'maxlength'=>100)); ?></td>
		<td><?php echo $form->error($model,'ControllerName'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'RuleTypeID'); ?></td>
		<td>: <?php echo CHtml::activeNumberField($model,'RuleTypeID',array('id' => 'txt_RuleTypeID', 'size'=>4)); ?> 
                    <?php echo CHtml::button('...', array('onclick'=>'$("#myDialog_RuleTypeID").dialog("open"); return false;',)); ?> 
                    <input type="text" id="lb_RuleTypeID" style="border: 0" readonly="">
                                        
                    <?php $this->beginWidget('zii.widgets.jui.CJuiDialog', array(
                            'id' => 'myDialog_RuleTypeID',
                            'options' => array('title' => 'Sysappaccessrule-RuleTypeID','width' => 600,'height' => 500,'autoOpen' => false,),
                            ));
                            $dialRuleTypeID = new myDialog();
                            $sourceRuleTypeID = $dialRuleTypeID->renderDialog("masterruletype", "RuleTypeID", "txt_RuleTypeID", "lb_RuleTypeID", "RuleTypeName", "#myDialog_RuleTypeID");
                            eval($sourceRuleTypeID);
                        ?>
                    <?php $this->endWidget('zii.widgets.jui.CJuiDialog'); ?> 
                </td>
		<td><?php echo $form->error($model,'RuleTypeID'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'RuleValues'); ?></td>
		<td>: <?php echo CHtml::activeTextField($model,'RuleValues',array('id' => 'txt_RuleValues','size'=>60,'maxlength'=>100)); ?></td>
		<td><?php echo $form->error($model,'RuleValues'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'isArrayRuleValues'); ?></td>
		<td>: <?php echo CHtml::activeCheckBox($model,'isArrayRuleValues', array('id' => 'cb_isArrayRuleValues')); ?></td>
		<td><?php echo $form->error($model,'isArrayRuleValues'); ?>
</td>
	</div>
    </tr>
    <tr>
	<div class="row">
		<td><?php echo $form->labelEx($model,'isActive'); ?></td>
		<td>: <?php echo CHtml::activeCheckBox($model,'isActive', array('id' => 'cb_isActive')); ?></td>
		<td><?php echo $form->error($model,'isActive'); ?>
</td>
	</div>
    </tr>
<tr>
    <td colspan="3">
	<div class="row buttons">
		<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
	</div>
    </td>
</tr>
</table>
</div>
<?php $this->endWidget(); ?>
<!-- form -->